function inPath = lookingForNodeInArray(node, array)
        AL = length(array);
          inPath = 0;
          for i = 1:AL
              n = array(i);
              if node == n
                  inPath = 1;
              end
          end
end